package com.ganbo.config;

import lombok.Data;
import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.context.annotation.Configuration;

/**
 * Redisson属性配置类
 *
 * @author jianglongtao
 * @date 2018年8月21日
 */
@Configuration
@ConfigurationProperties(prefix = "redisson")
@Data
public class RedissonProperties {
    private String address;
    private String password;
    // 超时时间，单位毫秒
    private int timeout = 30000;
    private int database = 0;
    private String sentinelAddress;
    private int connectionPoolSize = 20;
    private int connectionMiniumIdleSize = 10;
    private int slaveConnectionPoolSize = 100;
    private int masterConnectionPoolSize = 100;
    private String[] sentinelAddresses;
    private String[] masterAddresses;
    // 集群扫描间隔时间，单位毫秒
    private int scanInterval = 2000;
    private String masterName;

}
